<?php if(!defined('HDPHP_PATH'))exit;C('SHOW_NOTICE',FALSE);?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>无标题文档</title>
<link href="http://127.0.0.1/vancl_php/Application/Admin/View/css/style1.css" rel="stylesheet" type="text/css" />
<link rel="stylesheet" href="http://127.0.0.1/vancl_php/Static/css/hdjs.css" />
<script src="http://127.0.0.1/vancl_php/Static/js/jquery-1.7.2.min.js"></script>
<script src="http://127.0.0.1/vancl_php/Static/js/hdjs.min.js"></script>
<style>
	.hd-page span{
		
		color:black !important;
	}
	span{
		display: inline;
	}
</style>
<script type="text/javascript">


    function delMsg(id) {
        hd_modal({
            width: 400,//宽度
            height: 200,//高度
            title: '提示',//标题
            content: '您确定要删除这条类型属性吗?',//提示信息
            button: true,//显示按钮
            button_success: "确定",//确定按钮文字
            button_cancel: "关闭",//关闭按钮文字
            timeout: 0,//自动关闭时间 0：不自动关闭
            shade: false,//背景遮罩
            shadeOpacity: 0.9,//背景透明度
            success: function () {//点击确定后的事件
				location.href="http://127.0.0.1/vancl_php/index.php/Admin/TypeAttr/delAttr/id/"+id;
            },
            cancel: function () {//点击关闭后的事件

            }
        });
    }
</script>

</script>



</head>


<body>

	<div class="place">
    <span>位置：</span>
    <ul class="placeul">
    <li><a href="#">首页</a></li>
    <li><a href="#">类型管理</a></li>
    <li><a href="#">类型属性</a></li>
    </ul>
    </div>
    
    <div class="rightinfo">
    
    <div class="tools">
    
    	<ul class="toolbar">
        <li class="click"><a href="http://127.0.0.1/vancl_php/index.php/Admin/TypeAttr/addAttr/tid/<?php echo $hd['get']['tid'];?>"><span><img src="http://127.0.0.1/vancl_php/Application/Admin/View/images/t01.png" /></span>添加类型属性</a></li>
        <!--<li class="click"><span><img src="http://127.0.0.1/vancl_php/Application/Admin/View/images/t02.png" /></span>修改</li>
        <li><span><img src="http://127.0.0.1/vancl_php/Application/Admin/View/images/t03.png" /></span>删除</li>-->
        </ul>
        
        
        <ul class="toolbar1">
        <!--<li><span><img src="http://127.0.0.1/vancl_php/Application/Admin/View/images/t05.png" /></span>设置</li>-->
        </ul>
    
    </div>
    
    
    <table class="tablelist">
    	<thead>
    	<tr>
        <th>属性ID<i class="sort"><img src="http://127.0.0.1/vancl_php/Application/Admin/View/images/px.gif" /></i></th>
        <th>属性名称</th>
        <th>属性类别</th>
        <th>属性值 </th>
        <th>操作</th>
        </tr>
        </thead>
        <tbody>
        <?php foreach ($typeAttrs as $key=>$value){?>
        <tr>
        <td><?php echo $value['id'];?></td>
        <td><?php echo $value['attrname'];?></td>
        <td>    <?php if($value['attrtype']==0){ ?>属性<?php }else{ ?>规格<?php } ?></td>
        <td><?php echo $value['attrvalue'];?></td>
        <td><a href="http://127.0.0.1/vancl_php/index.php/Admin/TypeAttr/editAttr/id/<?php echo $value['id'];?>" class="hd-btn hd-btn-success hd-btn-sm" style=" display: inline;" >修改</a><a href="javascript:delMsg(<?php echo $value['id'];?>)" class="hd-btn hd-btn-danger hd-btn-sm" style=" display: inline;" >删除</a></td>
        </tr>    
        <?php }?>
        </tbody>
    </table>
  	<div class="hd-page"> 
   		<?php echo $page;?>
  	</div>
    </div>
    
    <script type="text/javascript">
	$('.tablelist tbody tr:odd').addClass('odd');
	</script>
	<script>
</script>
</body>

</html>
